from typing import List
from math import sin, cos, pi

xs:List[float] = [0.3535, 0.3535, 0.6464, 1.0607, 0.3535, -1.0607, -1.3535, -0.3535]
N:int = 8

def x(n:int)->float:
	return xs[n]

def Euler(theta:float)->complex:
	real:float = cos(theta)
	imag:float = sin(theta)
	return complex(real, imag)

def X(m:int)->complex:
	acc = complex()
	for n in range(0, N):
		theta:float = -2 * pi * n * m / N
		acc += Euler(theta) * x(n)
	return acc

for m in range(0, N):
	print(X(m))